package com.example.client;

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;

import org.eclipse.jetty.server.Server;
import org.eclipse.jetty.xml.XmlConfiguration;
import org.xml.sax.SAXException;

public class JettyServer {
	public static void main(String[] args) {
		XmlConfiguration configuration = null;
		try {
			configuration = new XmlConfiguration(new FileInputStream(args[0]));
		} catch (FileNotFoundException e1) {
			e1.printStackTrace();
		} catch (SAXException e1) {
			e1.printStackTrace();
		} catch (IOException e1) {
			e1.printStackTrace();
		}

		try {
			Server server = (Server) configuration.configure();
			server.start();
			server.join();
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
}
